const webpack = require("webpack");

module.exports = {
    runtimeCompiler: true,
    publicPath: './', // 设置打包文件相对路径
    devServer: {
        port: 8071,
        proxy: {
            '/api': {
                target: 'http://127.0.0.1:8100/', 
                changeOrigin: true,
                ws: true,
                pathRewrite: {
                    '^/api': ''
                }
            }
        }
    },
    configureWebpack: {
        plugins: [
            new webpack.ProvidePlugin({
                $: 'jquery',
                jQuery: 'jquery',
                'window.jQuery': 'jquery',
                Popper: ['popper.js', 'default']
            })
        ]
    }
}